package com.wuyou.single.service.impl;

import com.wuyou.single.dao.SysUserMapper;
import com.wuyou.single.domain.SysUser;
import com.wuyou.single.dto.login.CommonUserLoginDTO;
import com.wuyou.single.vo.UserInfoVO;
import com.wuyou.single.service.UserLoginService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * 用户登录service
 */
@Service
@Slf4j
public class UserLoginServiceImpl implements UserLoginService {

    @Resource
    private SysUserMapper sysUserMapper;


    /**
     * 登陆验证
     * @param dto
     * @return
     */
    @Override
    public UserInfoVO commonUserLogin(CommonUserLoginDTO dto) {
        // 用户名登陆
        SysUser userInfo = null;
        if (dto.getLoginType().matches("USERNAME")) {

        }

        if (userInfo == null) {
            throw new RuntimeException("");
        }
        return null;
    }
}
